<?php
namespace app\home\controller;

use app\home\model\Nation;

class Nations extends Base{
    //获取所有的民族
    public function getAllNation(){
        $nation =  collection(Nation::order("id","asc")->select())->toArray();
        return json($nation);
    }
    public function first()
    {
        $res = Nation::order("id asc")->find();
        echo  $res["name"];
    }
}